package org.jeecgframework.web.service;
import org.jeecgframework.web.system.pojo.base.TSUser;
import org.jeecgframework.web.system.pojo.base.ZyEquipmentSpareEntity;
import org.jeecgframework.core.common.service.CommonService;

import java.io.Serializable;
import java.util.List;

import javax.servlet.http.HttpServletRequest;

public interface ZyEquipmentSpareServiceI extends CommonService{
	
 	public <T> void delete(T entity);
 	
 	public <T> Serializable save(T entity);
 	
 	public <T> void saveOrUpdate(T entity);
 	
 	/**
	 * 默认按钮-sql增强-新增操作
	 * @param id
	 * @return
	 */
 	public boolean doAddSql(ZyEquipmentSpareEntity t);
 	/**
	 * 默认按钮-sql增强-更新操作
	 * @param id
	 * @return
	 */
 	public boolean doUpdateSql(ZyEquipmentSpareEntity t);
 	/**
	 * 默认按钮-sql增强-删除操作
	 * @param id
	 * @return
	 */
 	public boolean doDelSql(ZyEquipmentSpareEntity t);
 	
 	/**
 	 * @author xiul
 	 * 2016-3-28 下午6:02:14
 	 * Description 根据用户id查询 权限名 放入request里
 	 * @param req 
 	 * @param user 用户
 	 */
 	public void idandname(HttpServletRequest req, TSUser user);

    /**
     * 根据影院id查询该影院下的设备
     * */
    public List<ZyEquipmentSpareEntity> findEquipByCinemaId(String cinemaId);

    /**
     * 根据用户名查询设备信息
     * @param userName
     * @return
     */
    public List<ZyEquipmentSpareEntity> findEquipByUserName(String userName);


	/**
	 * 根据设备序列号查询设备信息
	 * @param sn
	 * @return
	 */
	public List<ZyEquipmentSpareEntity> findEquipBySn(String sn);


	/**
     * 检查bp
     * @param bp
     * @return zy:中影；hd：横店；orgCode:如果是其它直接返回orgCode
     */
    public String checkBP(String bp);
}
